<?php
global $Config;
require_once($Config->WebCMSRoot.'Base/Model.php');
require_once($Config->WebCMSRoot.'Data/User.php');

Class UserModel extends BaseModel
{
	var $Email;
	var $Password;
	var $FirstName;
	var $LastName;
	
	var $Roles;

	function UserModel()
	{
		$this->Email = '';
		$this->Password = ''; // sha1()
		$this->FirstName = '';
		$this->LastName = '';
		
		$this->Roles = array();
		
		parent::BaseModel();
	}
	
	function Retrieve(&$parameters)
	{
		$db = new UserData();
		$this->Parameters = &$parameters;
		
		$this->ID   		= $this->GetParameter('id');
		$this->Email 		= $this->GetParameter('email');
		$this->Password = $this->GetParameter('password');

		$db->Retrieve(&$this);
	}
}
?>